// by Xeno
private ["_selection", "_control", "_selectedIndex", "_real_list", "_vlist"];

disableSerialization;

_selection = _this select 0;

_control = _selection select 0;
_selectedIndex = _selection select 1;

if (_selectedIndex == -1) exitWith {};
_real_list = [60,80,100,120,140,160,180,200,250,300,400,500];
_index = -1;
{
	if (_x >= DM_AirTaxi_FlyingHeight) then {
		_index = _index + 1;
	};
	if (_index >= _selectedIndex) exitWith { DM_AirTaxi_SelectedHeight = _x; };
} foreach _real_list;
diag_log Format["(%1)[%2]: %3: %4 %5",diag_tickTime,"fhselchanged.sqf","New height", DM_AirTaxi_SelectedHeight, _this];
